﻿@model CustomerReturnRequestsModel
@using Nop.Web.Models.Customer;
@{
    Layout = "~/Views/Shared/_Root.cshtml";

    //title
    Html.AddTitleParts(T("PageTitle.Account").Text);
}
<div class="page account-page return-request-list-page">
    <div class="page-title">
        <h1>@T("Account.CustomerReturnRequests")</h1>
    </div>
    <div class="page-body">
        @if (Model.Items.Count > 0)
        {
            <ul data-role="listview" data-inset="true" data-filter="false">
                @foreach (var item in Model.Items)
                {
                    <li>
                        <div class="request-item">
                            <div class="title">
                                <strong>@string.Format(T("Account.CustomerReturnRequests.Title").Text, item.Id, item.ReturnRequestStatus)</strong>
                            </div>
                            <div class="product">
                                @T("Account.CustomerReturnRequests.Item") <a href="@Url.RouteUrl("Product", new { SeName = item.ProductSeName })" title="View details">@item.ProductName</a>
                                x @item.Quantity
                            </div>
                            <div class="reason">
                                @string.Format(T("Account.CustomerReturnRequests.Reason").Text, item.ReturnReason)
                            </div>
                            <div class="action">
                                @string.Format(T("Account.CustomerReturnRequests.Action").Text, item.ReturnAction)
                            </div>
                            <div class="date">
                                @string.Format(T("Account.CustomerReturnRequests.Date").Text, item.CreatedOn.ToString())
                            </div>
                            @if (!String.IsNullOrEmpty(item.Comments))
                            {<div class="comments-label">
                                    @T("Account.CustomerReturnRequests.Comments")
                                </div>
                                <div class="comments">
                                    @Html.Raw(Nop.Core.Html.HtmlHelper.FormatText(item.Comments, false, true, false, false, false, false))
                                </div>
                            }
                        </div>
                    </li>
                }
            </ul>
        }
    </div>
</div>
